
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8"/>
    <title>IconFont</title>
    <link rel="stylesheet" href="demo.css">
    <script src="iconfont.js"></script>

    <style type="text/css">
        .icon {
          /* 通过设置 font-size 来改变图标大小 */
          width: 1em; height: 1em;
          /* 图标和文字相邻时，垂直对齐 */
          vertical-align: -0.15em;
          /* 通过设置 color 来改变 SVG 的颜色/fill */
          fill: currentColor;
          /* path 和 stroke 溢出 viewBox 部分在 IE 下会显示
             normalize.css 中也包含这行 */
          overflow: hidden;
        }

    </style>
</head>
<body>
    <div class="main markdown">
        <h1>IconFont 图标</h1>
        <ul class="icon_lists clear">
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-star"></use>
                    </svg>
                    <div class="name">star</div>
                    <div class="fontclass">#icon-star</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-home"></use>
                    </svg>
                    <div class="name">home</div>
                    <div class="fontclass">#icon-home</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-star1"></use>
                    </svg>
                    <div class="name">star</div>
                    <div class="fontclass">#icon-star1</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-iconfontlingxing"></use>
                    </svg>
                    <div class="name">菱形-</div>
                    <div class="fontclass">#icon-iconfontlingxing</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-shouji"></use>
                    </svg>
                    <div class="name">手机</div>
                    <div class="fontclass">#icon-shouji</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-search"></use>
                    </svg>
                    <div class="name">search</div>
                    <div class="fontclass">#icon-search</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-close"></use>
                    </svg>
                    <div class="name">close</div>
                    <div class="fontclass">#icon-close</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-ok"></use>
                    </svg>
                    <div class="name">ok</div>
                    <div class="fontclass">#icon-ok</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-close3"></use>
                    </svg>
                    <div class="name">close</div>
                    <div class="fontclass">#icon-close3</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-close1"></use>
                    </svg>
                    <div class="name">close</div>
                    <div class="fontclass">#icon-close1</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-weixin"></use>
                    </svg>
                    <div class="name">微信</div>
                    <div class="fontclass">#icon-weixin</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-list"></use>
                    </svg>
                    <div class="name">List</div>
                    <div class="fontclass">#icon-list</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-jiankang"></use>
                    </svg>
                    <div class="name">健康</div>
                    <div class="fontclass">#icon-jiankang</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-dingdan01"></use>
                    </svg>
                    <div class="name">订单</div>
                    <div class="fontclass">#icon-dingdan01</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-close2"></use>
                    </svg>
                    <div class="name">close</div>
                    <div class="fontclass">#icon-close2</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-function1"></use>
                    </svg>
                    <div class="name">Function</div>
                    <div class="fontclass">#icon-function1</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-home1"></use>
                    </svg>
                    <div class="name">home</div>
                    <div class="fontclass">#icon-home1</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-ok1"></use>
                    </svg>
                    <div class="name">ok</div>
                    <div class="fontclass">#icon-ok1</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-yunshujuku"></use>
                    </svg>
                    <div class="name">云数据库</div>
                    <div class="fontclass">#icon-yunshujuku</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-download2"></use>
                    </svg>
                    <div class="name">download-2</div>
                    <div class="fontclass">#icon-download2</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-dot"></use>
                    </svg>
                    <div class="name">dot</div>
                    <div class="fontclass">#icon-dot</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-dropdown"></use>
                    </svg>
                    <div class="name">dropdown</div>
                    <div class="fontclass">#icon-dropdown</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-yiyuanhospital15"></use>
                    </svg>
                    <div class="name">医院_hospital15</div>
                    <div class="fontclass">#icon-yiyuanhospital15</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-xitong"></use>
                    </svg>
                    <div class="name">系统</div>
                    <div class="fontclass">#icon-xitong</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-photo"></use>
                    </svg>
                    <div class="name">photo</div>
                    <div class="fontclass">#icon-photo</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-iconfontyonghu"></use>
                    </svg>
                    <div class="name">icon-font-用户</div>
                    <div class="fontclass">#icon-iconfontyonghu</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-xinzeng-copy"></use>
                    </svg>
                    <div class="name">新增</div>
                    <div class="fontclass">#icon-xinzeng-copy</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-function"></use>
                    </svg>
                    <div class="name">function</div>
                    <div class="fontclass">#icon-function</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-cf-c101"></use>
                    </svg>
                    <div class="name">新增</div>
                    <div class="fontclass">#icon-cf-c101</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-baocun"></use>
                    </svg>
                    <div class="name">保存</div>
                    <div class="fontclass">#icon-baocun</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-weibiaoti302"></use>
                    </svg>
                    <div class="name">健康日用品</div>
                    <div class="fontclass">#icon-weibiaoti302</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-dropdown1"></use>
                    </svg>
                    <div class="name">dropdown</div>
                    <div class="fontclass">#icon-dropdown1</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-photo1"></use>
                    </svg>
                    <div class="name">photo</div>
                    <div class="fontclass">#icon-photo1</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-iconfontdatabase"></use>
                    </svg>
                    <div class="name">hy-database</div>
                    <div class="fontclass">#icon-iconfontdatabase</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-dropdown2"></use>
                    </svg>
                    <div class="name">dropdown</div>
                    <div class="fontclass">#icon-dropdown2</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-kuaidi"></use>
                    </svg>
                    <div class="name">快递</div>
                    <div class="fontclass">#icon-kuaidi</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-dot-right"></use>
                    </svg>
                    <div class="name">dot-right</div>
                    <div class="fontclass">#icon-dot-right</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-photo2"></use>
                    </svg>
                    <div class="name">photo</div>
                    <div class="fontclass">#icon-photo2</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-mima"></use>
                    </svg>
                    <div class="name">密码</div>
                    <div class="fontclass">#icon-mima</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-icon_hospital"></use>
                    </svg>
                    <div class="name">icon_hospital</div>
                    <div class="fontclass">#icon-icon_hospital</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-upload"></use>
                    </svg>
                    <div class="name">upload</div>
                    <div class="fontclass">#icon-upload</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-zhifubao"></use>
                    </svg>
                    <div class="name">支付宝</div>
                    <div class="fontclass">#icon-zhifubao</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-biaoqian"></use>
                    </svg>
                    <div class="name">标签</div>
                    <div class="fontclass">#icon-biaoqian</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-reset"></use>
                    </svg>
                    <div class="name">reset</div>
                    <div class="fontclass">#icon-reset</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-xiugai"></use>
                    </svg>
                    <div class="name">修改 (1)</div>
                    <div class="fontclass">#icon-xiugai</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-left"></use>
                    </svg>
                    <div class="name">left</div>
                    <div class="fontclass">#icon-left</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-baocun1"></use>
                    </svg>
                    <div class="name">保存</div>
                    <div class="fontclass">#icon-baocun1</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-xitong1"></use>
                    </svg>
                    <div class="name">系统</div>
                    <div class="fontclass">#icon-xitong1</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-lajitong"></use>
                    </svg>
                    <div class="name">垃圾桶</div>
                    <div class="fontclass">#icon-lajitong</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-xinxituisong"></use>
                    </svg>
                    <div class="name">信息推送</div>
                    <div class="fontclass">#icon-xinxituisong</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-lingxing"></use>
                    </svg>
                    <div class="name">菱形</div>
                    <div class="fontclass">#icon-lingxing</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-daochu"></use>
                    </svg>
                    <div class="name">导出</div>
                    <div class="fontclass">#icon-daochu</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-icon-"></use>
                    </svg>
                    <div class="name">扫一扫</div>
                    <div class="fontclass">#icon-icon-</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-upload-demo"></use>
                    </svg>
                    <div class="name">download</div>
                    <div class="fontclass">#icon-upload-demo</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-bingxiang"></use>
                    </svg>
                    <div class="name">冰箱</div>
                    <div class="fontclass">#icon-bingxiang</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-zhanghu"></use>
                    </svg>
                    <div class="name">账户</div>
                    <div class="fontclass">#icon-zhanghu</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-notebook"></use>
                    </svg>
                    <div class="name">笔记本</div>
                    <div class="fontclass">#icon-notebook</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-yinhangqia"></use>
                    </svg>
                    <div class="name">银行卡</div>
                    <div class="fontclass">#icon-yinhangqia</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-wangluo"></use>
                    </svg>
                    <div class="name">网络</div>
                    <div class="fontclass">#icon-wangluo</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-character"></use>
                    </svg>
                    <div class="name">人物</div>
                    <div class="fontclass">#icon-character</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-AppStore"></use>
                    </svg>
                    <div class="name">App Store</div>
                    <div class="fontclass">#icon-AppStore</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-xuanxiang"></use>
                    </svg>
                    <div class="name">menu-fill</div>
                    <div class="fontclass">#icon-xuanxiang</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-wo"></use>
                    </svg>
                    <div class="name">我</div>
                    <div class="fontclass">#icon-wo</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-sangedian"></use>
                    </svg>
                    <div class="name">三个点</div>
                    <div class="fontclass">#icon-sangedian</div>
                </li>
            
        </ul>


        <h2 id="symbol-">symbol引用</h2>
        <hr>

        <p>这是一种全新的使用方式，应该说这才是未来的主流，也是平台目前推荐的用法。相关介绍可以参考这篇<a href="">文章</a>
        这种用法其实是做了一个svg的集合，与另外两种相比具有如下特点：</p>
        <ul>
          <li>支持多色图标了，不再受单色限制。</li>
          <li>通过一些技巧，支持像字体那样，通过<code>font-size</code>,<code>color</code>来调整样式。</li>
          <li>兼容性较差，支持 ie9+,及现代浏览器。</li>
          <li>浏览器渲染svg的性能一般，还不如png。</li>
        </ul>
        <p>使用步骤如下：</p>
        <h3 id="-symbol-">第一步：引入项目下面生成的symbol代码：</h3>
        <pre><code class="lang-js hljs javascript"><span class="hljs-comment">&lt;script src="./iconfont.js"&gt;&lt;/script&gt;</span></code></pre>
        <h3 id="-css-">第二步：加入通用css代码（引入一次就行）：</h3>
        <pre><code class="lang-js hljs javascript">&lt;style type=<span class="hljs-string">"text/css"</span>&gt;
.icon {
   width: <span class="hljs-number">1</span>em; height: <span class="hljs-number">1</span>em;
   vertical-align: <span class="hljs-number">-0.15</span>em;
   fill: currentColor;
   overflow: hidden;
}
&lt;<span class="hljs-regexp">/style&gt;</span></code></pre>
        <h3 id="-">第三步：挑选相应图标并获取类名，应用于页面：</h3>
        <pre><code class="lang-js hljs javascript">&lt;svg <span class="hljs-class"><span class="hljs-keyword">class</span></span>=<span class="hljs-string">"icon"</span> aria-hidden=<span class="hljs-string">"true"</span>&gt;<span class="xml"><span class="hljs-tag">
  &lt;<span class="hljs-name">use</span> <span class="hljs-attr">xlink:href</span>=<span class="hljs-string">"#icon-xxx"</span>&gt;</span><span class="hljs-tag">&lt;/<span class="hljs-name">use</span>&gt;</span>
</span>&lt;<span class="hljs-regexp">/svg&gt;
        </span></code></pre>
    </div>
</body>
</html>
